class MyThread2 implements Runnable{
    @Override
    public void run() {
        System.out.println("线程创建的第二种方法");
    }
}
public class Demo02 {
    public static void main1(String[] args) {
        MyThread2 myThread2 = new MyThread2();

        Thread t1 = new Thread(myThread2);

        t1.start();

    }

}
